//
//  AlertView.m
//  Bracelet
//
//  Created by Jayce on 15/3/10.
//  Copyright (c) 2015年 jing zhao. All rights reserved.
//

#import "BluetoothConfirmView.h"

static BluetoothConfirmView *_instance = nil;

@implementation BluetoothConfirmView


+(BluetoothConfirmView *)shareInstance{
  
  static dispatch_once_t onceToken;
  dispatch_once(&onceToken, ^{
    _instance = [[BluetoothConfirmView alloc] init];
  });
  return _instance;
}

-(instancetype)init{
  self = [super init];
  if (self) {
    
  }
  return self;
}

+(id)allocWithZone:(struct _NSZone *)zone{
  static dispatch_once_t onceToken;
  dispatch_once(&onceToken, ^{
    _instance = [super allocWithZone:zone];
  });
  return _instance;
}

-(id)copyWithZone:(NSZone *)zone{
  return _instance;
}

- (IBAction)confirmRetryClicked:(id)sender {
  [self.confirmDelegate confirmRertyClicked];
  [self removeFromSuperview];
//  if([[[UIDevice currentDevice] systemVersion] floatValue]<8.0)
//  {
//    UIAlertView* curr1=[[UIAlertView alloc] initWithTitle:@"This app does not have access to Location service" message:@"You can enable access in Settings->Privacy->Location->Location Services" delegate:self cancelButtonTitle:@"OK" otherButtonTitles:nil, nil];
//    [curr1 show];
//  }else{
//    [[UIApplication sharedApplication] openURL:[NSURL  URLWithString:UIApplicationOpenSettingsURLString]];
//  }
}

- (IBAction)confirmCancelClicked:(id)sender {
  [self removeFromSuperview];
}

@end
